/*
 *   Copyright 2021 zzh
 *
 *   Licensed under the Apache License, Version 2.0 (the "License");
 *   you may not use this file except in compliance with the License.
 *   You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 *   Unless required by applicable law or agreed to in writing, software
 *   distributed under the License is distributed on an "AS IS" BASIS,
 *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *   See the License for the specific language governing permissions and
 *   limitations under the License.
 *
 */

package com.aduib.boot.web.context.response;

/**
 * @description: ResponseCodeEnum
 * @author: zzh
 * @date: 2021/9/6 17:03
 */
public enum ResponseCodeEnum {
  SUCCESS(0,"请求成功"),
  FAILURE(1,"请求失败"),
  UNAUTHORIZED(-1,"token失效"),
  ILLEGAL_ARGUMENT_EXCEPTION(-3,"参数错误"),
  SYS_EXCEPTION(-2,"系统异常");


  private Integer code;

  private String message;

  ResponseCodeEnum(Integer code, String message) {
    this.code = code;
    this.message = message;
  }

  public Integer getCode() {
    return code;
  }

  public String getMessage() {
    return message;
  }
}
